import request from '@/utils/request'

// 查询机场禁飞区列表
export function listAirport(query) {
  return request({
    url: '/manage/airport/list',
    method: 'get',
    params: query
  })
}

// 查询机场禁飞区详细
export function getAirport(id) {
  return request({
    url: '/manage/airport/' + id,
    method: 'get'
  })
}

// 新增机场禁飞区
export function addAirport(data) {
  return request({
    url: '/manage/airport',
    method: 'post',
    data: data
  })
}

// 修改机场禁飞区
export function updateAirport(data) {
  return request({
    url: '/manage/airport',
    method: 'put',
    data: data
  })
}

// 删除机场禁飞区
export function delAirport(id) {
  return request({
    url: '/manage/airport/' + id,
    method: 'delete'
  })
}
